Program Fusion with Paramorphisms
نویسندگان
چکیده
The design of programs as the composition of smaller ones is a wide spread approach to programming. In functional programming, this approach raises the necessity of creating a good amount of intermediate data structures with the only aim of passing data from one function to another. Using program fusion techniques, it is possible to eliminate many of those intermediate data structures by an appropriate combination of the codes of the involved functions. In the standard case, no mention to the eliminated data structure remains in the code obtained from fusion. However, there are situations in which parts of that data structure becomes an internal value manipulated by the fused program. This happens, for example, when primitive recursive functions (socalled paramorphisms) are involved. We show, for example, that the result of fusing a primitive recursive function p with another function f may give as result a function that contains calls to f . Moreover, we show that in some cases the result of fusion may be less efficient than the original composition. We also investigate a general recursive version of paramorphism. This study is strongly motivated by the development of a fusion tool for Haskell programs called HFUSION.
منابع مشابه
Role of Minimally Invasive Spine Surgery in Adults with Degenerative Lumbar Scoliosis: A Narrative Review
Background and Aim: Degenerative lumbar scoliosis is a spinal deformity resulting from advanced disc degeneration and facet arthropathy. Given the inconclusive available literature and lack of high-quality data supporting the role of minimally invasive surgical management of degenerative lumbar scoliosis, this review intends to highlight and compare the various viable minimally invasive surgica...
متن کامل"Bagatelle in C arranged for VDM SoLo"
This paper sketches a reverse engineering discipline which combines formal and semi-formal methods. Central to the former is denotational semantics, expressed in the ISO/IEC 13817-1 standard specification language (VDM-SL). This is strengthened with algebra of programming, which is applied in “reverse order” so as to reconstruct formal specifications from legacy code. The latter include code sl...
متن کاملAlgebraic Specialization of Generic Functions for Recursive Types
Defining functions over large, possibly recursive, data structures usually involves a lot of boilerplate. This code simply traverses non-interesting parts of the data, and rapidly becomes a maintainability problem. Many generic programming libraries have been proposed to address this issue. Most of them allow the user to specify the behavior just for the interesting bits of the structure, and p...
متن کاملمقایسه روند بالینی بیماران مبتلا به ضایعات دیسکال گردنی در روشهای دیسککتومی قدامی گردن بدون فیوژن، همراه با فیوژن استخوانی از کرست ایلیاک و استفاده از کیج PEEK
Background & Objective : The preferred Selection of the anterior cervical discectomy alone, with iliac crest bone graft fusion and using the PEEK cage is still in controversial in degenerative disc disease. The aim of this study is comparing them on radiographic and clinical results. Materials & Methods: The all consecutive patients in the three hospitals in Tehran between the 2000 up to the ...
متن کاملEnergy Gain of Magnetized Cylindrical D-T Targets in Fast Ignition Fusion
In recent years, many different plans have been considered to use the nuclear energy gained from inertial confinement fusion (ICF) as attempts to obtain high energy efficiencies. In conventional ICF methods, a small amount (about mg) of the deuterium–tritium compound is confined in a small spherical chamber of a few millimeters in radius and compressed by laser or heavy ion beams with powers in...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2006